/**
 * 
 */
package org.statewalker.core.server;

import java.util.logging.Level;
import java.util.logging.Logger;

import org.statewalker.core.ErrorEvent;
import org.statewalker.core.IEvent;
import org.statewalker.core.SyncState;

/**
 * @author kotelnikov
 */
public class ServerSyncState extends SyncState {

    private final Logger log = Logger
        .getLogger(ServerSyncState.class.getName());

    @Override
    public ServerContext getContext() {
        return (ServerContext) super.getContext();
    }

    protected IEvent handleEvent(Throwable t) {
        log.log(Level.WARNING, "Error!", t);
        return new ErrorEvent(t);
    }
}
